﻿//Write an expression that checks for given integer 
//if its third digit (right-to-left) is 7. E. g. 1732 -> true.


using System;

namespace CheckThirdDigit
{
    class FindSeven
    {
        static void Main()
        {
            Console.Write("Please enter a four digit number:");
            int a = int.Parse (Console.ReadLine());

            int b = a / 100;

            int c = b % 10;

            if (c == 7)
            {
                Console.WriteLine("The third digit of the number is 7.");
            }
            else
            {
                Console.WriteLine("The third digit of the number is not 7.");
            }
        }
    }
}
